package genetic.q3.functions;

import genetic.TreeNode;

public class DoubleConstant extends SymbolicRegressionTerminal{
	double val;

	public DoubleConstant(double val) {
		this.val = val;
	}

	@Override
	public TreeNode clone() {
		return new DoubleConstant(val);
	}

	@Override
	public String getName() {
		return val+"";
	}

	@Override
	public double compute(double xVal) {
		return val;
	}
}
